
import requests
import json

headers = {
    "User-Agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/114.0.0.0 Safari/537.36"
}

# post 请求
urlpost = 'https://fanyi.baidu.com/sug'
data = {
    'kw': '标题'
}

pxoxies = {
    'https': '代理ip:端口'
}

response = requests.post(url=urlpost, data=data, headers=headers, proxies=pxoxies)

content = response.text
print(json.loads(content))